app.service("userService",function($http){
	
	
	//登录
	this.login=function(name,pwd){
		//alert("datas===="+datas.toString())
		return $http({
				method : "POST",
				url : "/test/Login",
				data : {
					'name' : name,
					'password':pwd
				}
		});
	}
	
	
	
	//注册
	this.register=function(name,pwd,email,phonenumber){
		//alert("datas===="+datas.toString())
		return $http({
				method : "POST",
				url : "/test/Register",
				data : {
					'name' : name,
					'password':pwd,
					'email':email,
					'tel':phonenumber
				}
		});
	}
	
	
	
	
	
})